﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace MyWeb.AdminControl
{
    public partial class TopAd : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                //xinchao();
            }

        }
        protected void logout_Click(object sender, EventArgs e)
        {
            Session["CusIdadmin"] = null;
            Session["Usernameadmin"] = null;            
            Response.Redirect("/Default.aspx");
        }
        protected void xinchao()
        {
            if (Session["CusIdadmin"] != null)
            {
                lbladmin.Text = "Xin Chào :" + Session["Usernameadmin"].ToString();
            }
            else
            {
                Response.Redirect("/Default.aspx");
            }
        }
    }
}